package com.rajeshDyadav.serialization;

import java.io.*;

public class Serialize {
    public static void main(String[] args) throws IOException {
	Employee e = new Employee();
	e.name = "Rajesh D. Yadav";
	e.address = "Palghar";
	e.SSN = 7749;
	e.number = 77;
	e.dId = "007";
	e.dName = "Dev";
	e.location = "India";
	FileOutputStream fileOut = new FileOutputStream("employee.txt");
	ObjectOutputStream out = new ObjectOutputStream(fileOut);
	out.writeObject(e);
	out.close();
	fileOut.close();
    }
}
